/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package asteroide;

import java.awt.Polygon;
import java.awt.Rectangle;

/**
 *
 * @author Jose Carlos Palma
 */
public class Asteroid extends BaseVectorShape {

    private int[] astx = {-20, -13, 0, 20, 22, 20, 12, 2, -10, -22, 16};
    private int[] asty = {20, 23, 17, 20, 16, -20, -22, -14, -17, -20, -5};
    private static final int LENGTH = 11;
    
    private double rotVel = 0.0;
    
    
    public Asteroid(){
        setShape(new Polygon(astx, asty, LENGTH));
        setAlive(true);
        this.rotVel = 0.0;
    }
    
    /**
     * @return the rotVel
     */
    public double getRotationVelocity() {
        return rotVel;
    }

    /**
     * @param rotVel the rotVel to set
     */
    public void setRotationVelocity(double rotVel) {
        this.rotVel = rotVel;
    }
    
    public Rectangle getBounds() {
        return new Rectangle((int) getX()-20, (int) getY()-20, 40, 40);
    }
    
    
    
}
